package com.heima.wemedia.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.heima.model.wemedia.dto.NewsAuthDto;
import com.heima.model.wemedia.pojo.WmNews;
import com.heima.model.wemedia.pojo.WmUser;
import com.heima.model.wemedia.vo.WmNewsVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * Created by ZYJ on 2021/5/28 21:29
 */
@Mapper
public interface WmNewsMapper extends BaseMapper<WmNews> {

    /**
     * 分页查询文章列表
     * @param dto
     * @return
     */
    List<WmNewsVo> findListAndPage(@Param("dto") NewsAuthDto dto);

    /**
     * 总数量
     * @param dto
     * @return
     */
    long findListCount(@Param("dto")NewsAuthDto dto);
}
